package com.hb.gp.util.command;

import com.hb.gp.util.MsgGenUtil;

public class APDU_InitializeUpdate {
	/**
	 * 获取初始化通道指令
	 * */
	public static String getInitUpdateCommand(String p1, String random){
		String p2 = "00";
        int dataLen = random.length() / 2;
        StringBuffer buf = new StringBuffer();
        buf.append("8050");
        buf.append(p1);
        buf.append(p2);
        buf.append(MsgGenUtil.buf2hex(MsgGenUtil.Int2Bytes1(dataLen)));
        buf.append(random);
        //buf.append("00");
        return buf.toString();
	}
}
